#include<iostream>
#include<vector>
#include<algorithm>

using namespace std;

static bool my_cmp(pair<int,int>p1,pair<int,int>p2)
{
    if (p1.first > p2.first)
    {
        return true;
    }
    return false;
}

vector<string> sortPeople(vector<string>& names, vector<int>& heights) {

    vector<pair<int, int>>nums(heights.size(), {0,0});
    for (int i = 0; i < heights.size(); i++)
    {
        nums[i] = { heights[i],i};
    }
    sort(nums.begin(), nums.end(), my_cmp);

    vector<string>restr(heights.size());

    for (int i = 0; i < heights.size(); i++)
    {
        restr[i] = names[nums[i].second];
    }

    return restr;
    
    
}



int main()
{
	return 0;
}